﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using RoadTeam.BLL.FM;
using System.Data;
using System.Web.Script.Serialization;
using RoadTeam.Standard.FM;
using RoadTeam.Pase.FM;

public partial class 对接测试页面_FM_FmMeterDegree : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void Button1_Click(object sender, EventArgs e)
    {


        MeterDegree Degree = new MeterDegree();
        List<MeterDegree> li = new List<MeterDegree>();
        Degree.DegreeID = "34028";
        Degree.UnitName = "0401";
        Degree.UnitCode = "A20401";
        Degree.MeterName = "电表";
        Degree.MeterCode = "CFDB01141279";
        Degree.PreDegree = "10000.00";
        Degree.CurDegree = "263.00";
        Degree.Degree = "11111111.00";
        Degree.Times = "0.001";
        Degree.Capacity = "999999";
        li.Add(Degree);

        Degree = new MeterDegree();
        Degree.DegreeID = "34029";
        Degree.UnitName = "0401";
        Degree.UnitCode = "A20401";
        Degree.MeterName = "水表";
        Degree.MeterCode = "CFDB01141279";
        Degree.PreDegree = "172.00";
        Degree.CurDegree = "10000";
        Degree.Degree = "9828";
        Degree.Times = "0.001";
        Degree.Capacity = "999999";
        li.Add(Degree);
        RoadTeam.Standard.FM.FmMeterDegree fmdegree = new FmMeterDegree();
        fmdegree.Item = li.ToArray();

        JavaScriptSerializer jvs = new JavaScriptSerializer();
        TextBox1.Text = jvs.Serialize(fmdegree);
    }
    protected void Button2_Click(object sender, EventArgs e)
    {
        MeterDegreePase.UpdateMeterDegree(TextBox1.Text);
    }
}